package com.khiker.binary;

public class P190_ReverseBits {
	public int reverseBits(int n) {
		int res = 0, i = 31;
		while (i >= 0) {
			res |= (n & 1) << i--;
			n >>>= 1;
		}
		return res;
	}

	public static void main(String[] args) {
		P190_ReverseBits reverseBits190 = new P190_ReverseBits();
		System.out.println(reverseBits190.reverseBits(-3));
	}

}
